*** Set working directory ***
cd "C:\..."

*********************** Load Data **********************************************
clear
graph drop _all
cap drop all

use Firm_Level

************************** Setup ***********************************************
sort date

* Merge & Standardize Quarterly MP Shock series
merge m:1 date using fomc_GSW_yields_qtr
drop if _merge != 3
drop _merge
egen mps_std = sd(chg_sveny02)
gen mps = chg_sveny02/mps_std

sort gvkey date
xtset gvkey date

replace invest = invest*100 

***************************** Sum Stats **************************************
winsor2 invest, replace cuts(1 99)
sum invest if mps !=. & gscpi !=. & L.current != . & L.salesg != . & L.size != . & L.ptoc != . & L.rmptos != . & L.dtoa != . & L.age != . & L.cap != . & L.levg != . & L.lqdty != ., detail
sum age if mps !=. & gscpi !=. & L.current != . & L.salesg != . & L.size != . & L.ptoc != . & L.rmptos != . & L.dtoa != . & L.age != . & L.cap != . & L.levg != . & L.lqdty != . & invest != ., detail
sum size if mps !=. & gscpi !=. & L.current != . & L.salesg != . & L.size != . & L.ptoc != . & L.rmptos != . & L.dtoa != . & L.age != . & L.cap != . & L.levg != . & L.lqdty != . & invest != ., detail
sum current if mps !=. & gscpi !=. & L.current != . & L.salesg != . & L.size != . & L.ptoc != . & L.rmptos != . & L.dtoa != . & L.age != . & L.cap != . & L.levg != . & L.lqdty != . & invest != ., detail
sum salesg if mps !=. & gscpi !=. & L.current != . & L.salesg != . & L.size != . & L.ptoc != . & L.rmptos != . & L.dtoa != . & L.age != . & L.cap != . & L.levg != . & L.lqdty != . & invest != ., detail
sum ptoc if mps !=. & gscpi !=. & L.current != . & L.salesg != . & L.size != . & L.ptoc != . & L.rmptos != . & L.dtoa != . & L.age != . & L.cap != . & L.levg != . & L.lqdty != . & invest != ., detail
sum rmptos if mps !=. & gscpi !=. & L.current != . & L.salesg != . & L.size != . & L.ptoc != . & L.rmptos != . & L.dtoa != . & L.age != . & L.cap != . & L.levg != . & L.lqdty != . & invest != ., detail
sum dtoa if mps !=. & gscpi !=. & L.current != . & L.salesg != . & L.size != . & L.ptoc != . & L.rmptos != . & L.dtoa != . & L.age != . & L.cap != . & L.levg != . & L.lqdty != . & invest != ., detail
sum cap if mps !=. & gscpi !=. & L.current != . & L.salesg != . & L.size != . & L.ptoc != . & L.rmptos != . & L.dtoa != . & L.age != . & L.cap != . & L.levg != . & L.lqdty != . & invest != ., detail
sum levg if mps !=. & gscpi !=. & L.current != . & L.salesg != . & L.size != . & L.ptoc != . & L.rmptos != . & L.dtoa != . & L.age != . & L.cap != . & L.levg != . & L.lqdty != . & invest != ., detail
sum lqdty if mps !=. & gscpi !=. & L.current != . & L.salesg != . & L.size != . & L.ptoc != . & L.rmptos != . & L.dtoa != . & L.age != . & L.cap != . & L.levg != . & L.lqdty != . & invest != ., detail

********************************************************************************